using System;
using Neo.Generator.Core;
using Neo.MetaModel;

namespace Webbness.VsTool
{
    [Serializable]
    public class ResourceCodeGenerationContext : GenerationContext
    {
        private Entity _entity;
        private ModelHelper _helper;

        public ResourceCodeGenerationContext(Entity entity)
        {
            _entity = entity;
            _helper = new ModelHelper(entity);
        }

        public override string ToString()
        {
            return "ResourceCodeGenerationContext";
        }

        public Entity Entity
        {
            get { return _entity; }
        }

        public string FileName
        {
            get { return (_entity.ClassName + "Resource.resx"); }
        }

        public ModelHelper Helper
        {
            get { return _helper; }
        }

        public override Model Model
        {
            get { return _entity.Model; }
        }
    }
}